<?php


	class Shop_type_attrModel extends Model{

		public $table = 'shop_type_attr';


		public $validate = array(

			array('taname','nonull','名称不能为空',2,3),
			array('tavalue','nonull','属性值不能为空',2,3),

			);

		//添加数据
		public function add_data($tid){
			if (!$this->create()) {
				
				return false;
			}
			return $this->add();
		}

		public function edit_data($taid){
			if (!$this->create()) {

				return false;
			}
			return $this->where("taid={$taid}")->update();
		}


	}











?>